"""gma URL Configuration

The `urlpatterns` list routes URLs to views. For more information please see:
    https://docs.djangoproject.com/en/1.11/topics/http/urls/
Examples:
Function views
    1. Add an import:  from my_app import views
    2. Add a URL to urlpatterns:  url(r'^$', views.home, name='home')
Class-based views
    1. Add an import:  from other_app.views import Home
    2. Add a URL to urlpatterns:  url(r'^$', Home.as_view(), name='home')
Including another URL conf
    1. Import the include() function: from django.conf.urls import url, include
    2. Add a URL to urlpatterns:  url(r'^blog/', include('blog.urls'))
"""

from django.conf.urls import url
from django.views.decorators.csrf import csrf_exempt

from apps.api import views_pipe

urlpatterns = [
    # [520]获取520配对活动榜单的请求
    # @req:
    #     - uid: 用户uid
    #
    # @ack:
    #     - pairs: 配对列表
    #     - rank: 当前排名
    #     - score: 当前分数
    #     - paired_uid: 配对用户id
    #     - has_taken_reward: 是否领取过奖励
    url(r'^get520_pair_activity_info/$', csrf_exempt(views_pipe.get520_pair_activity_info), name='get520_pair_activity_info'),

    # [520]领取520配对活动奖励的请求
    # @req:
    #     - uid: 用户uid
    #
    # @ack:
    url(r'^take520_pair_activity_reward/$', csrf_exempt(views_pipe.take520_pair_activity_reward), name='take520_pair_activity_reward'),

    # [61]获取六一活动信息的请求
    # @req:
    #     - uid: 用户uid
    #
    # @ack:
    #     - formulas: 配方列表
    #     - reward_icon: 奖励图标
    url(r'^get61_activity_info/$', csrf_exempt(views_pipe.get61_activity_info), name='get61_activity_info'),

    # [61]领取六一活动奖励的请求
    # @req:
    #     - uid: 用户uid
    #     - formula_id: 配方id
    #
    # @ack:
    url(r'^take61_activity_reward/$', csrf_exempt(views_pipe.take61_activity_reward), name='take61_activity_reward'),

    # [ACTIVITY]获取宝箱产出的请求
    # @req:
    #     - uid: 用户uid
    #
    # @ack:
    #     - gift_box_list: 宝箱列表
    url(r'^get_gift_box_output/$', csrf_exempt(views_pipe.get_gift_box_output), name='get_gift_box_output'),

    # [DRAGON_BOAT]获取端午节活动信息请求
    # @req:
    #     - uid: 用户uid
    #
    # @ack:
    #     - begin_time: 活动开始时间
    #     - end_time: 活动结束时间
    #     - total_pay_amount: 累充充值金额
    #     - options: 奖励选项
    url(r'^get_dragon_boat_activity_info/$', csrf_exempt(views_pipe.get_dragon_boat_activity_info), name='get_dragon_boat_activity_info'),

    # [DRAGON_BOAT]获取端午节活动排行榜请求
    # @req:
    #     - uid: 用户uid
    #
    # @ack:
    #     - rooms: 房间列表
    url(r'^get_dragon_boat_ranking/$', csrf_exempt(views_pipe.get_dragon_boat_ranking), name='get_dragon_boat_ranking'),

    # [DRAGON_BOAT]领取端午节活动奖励请求
    # @req:
    #     - uid: 用户uid
    #     - amount: 充值金额
    #
    # @ack:
    url(r'^take_dragon_boat_activity_reward/$', csrf_exempt(views_pipe.take_dragon_boat_activity_reward), name='take_dragon_boat_activity_reward'),

    # [MASTER]关闭接单请求
    # @req:
    #     - uid: 用户uid
    #     - skill_id: 技能id
    #
    # @ack:
    url(r'^disable_master_skill/$', csrf_exempt(views_pipe.disable_master_skill), name='disable_master_skill'),

    # [MASTER]开启接单请求
    # @req:
    #     - uid: 用户uid
    #     - skill_id: 技能id
    #
    # @ack:
    url(r'^enable_master_skill/$', csrf_exempt(views_pipe.enable_master_skill), name='enable_master_skill'),

    # [MASTER]更新大神设置请求
    # @req:
    #     - uid: 用户uid
    #     - begin_point: 服务开始时间(hhmm)
    #     - end_point: 服务结束时间(hhmm)
    #     - week_day1: 周一是否接单
    #     - week_day2: 周二是否接单
    #     - week_day3: 周三是否接单
    #     - week_day4: 周四是否接单
    #     - week_day5: 周五是否接单
    #     - week_day6: 周六是否接单
    #     - week_day7: 周日是否接单
    #
    # @ack:
    url(r'^update_master_settings/$', csrf_exempt(views_pipe.update_master_settings), name='update_master_settings'),

    # [MASTER]申请成为大神请求
    # @req:
    #     - uid: 用户uid
    #     - skill_id: 技能id
    #     - skill_screenshot: 技能截图(上传图片的token类型为 UPLOAD_FILE_SKILL)
    #     - skill_tags_json: 技能标签json(标签id的json数组)
    #     - skill_rank: 技能段位
    #     - audio: 音频介绍(上传图片的token类型为 UPLOAD_FILE_SKILL)
    #     - description: 描述信息
    #     - avatar: 大神头像(上传图片的token类型为 UPLOAD_FILE_SKILL)
    #
    # @ack:
    url(r'^apply_for_master/$', csrf_exempt(views_pipe.apply_for_master), name='apply_for_master'),

    # [MASTER]编辑技能请求
    # @req:
    #     - uid: 用户uid
    #     - skill_id: 技能id
    #     - skill_screenshot: 技能截图(上传图片的token类型为 UPLOAD_FILE_SKILL)
    #     - skill_tags_json: 技能标签json(标签id的json数组)
    #     - skill_rank: 技能段位
    #     - audio: 技能截图(上传图片的token类型为 UPLOAD_FILE_SKILL)
    #     - description: 描述信息
    #     - avatar: 大神头像(上传图片的token类型为 UPLOAD_FILE_SKILL)
    #     - is_main_skill: 是否设置成主技能(0:不设置, 1:设置)
    #     - price: 价格
    #
    # @ack:
    url(r'^edit_master_skill/$', csrf_exempt(views_pipe.edit_master_skill), name='edit_master_skill'),

    # [MASTER]获取Banner列表请求
    # @req:
    #     - uid: 自己的uid
    #     - banner_type: banner类型(参见 ACBannerTypeDefine)
    #
    # @ack:
    #     - banners: Banner列表
    url(r'^get_banner_list/$', csrf_exempt(views_pipe.get_banner_list), name='get_banner_list'),

    # [MASTER]获取大神信息请求
    # @req:
    #     - uid: 用户uid
    #     - mid: 大神uid
    #
    # @ack:
    #     - master: 大神信息
    #     - skills: 技能列表
    #     - has_unread_order_status: 是否有未读的订单状态
    url(r'^get_master_info/$', csrf_exempt(views_pipe.get_master_info), name='get_master_info'),

    # [MASTER]获取大神技能信息请求
    # @req:
    #     - uid: 用户uid
    #     - mid: 大神uid
    #     - skill_id: 技能id
    #
    # @ack:
    #     - master: 大神信息
    #     - skill: 技能信息
    url(r'^get_master_skill_info/$', csrf_exempt(views_pipe.get_master_skill_info), name='get_master_skill_info'),

    # [MASTER]获取大神技能编辑信息请求
    # @req:
    #     - uid: 用户uid
    #     - skill_id: 技能id
    #
    # @ack:
    #     - master: 大神信息
    #     - skill: 技能信息
    url(r'^get_master_skill_edit_info/$', csrf_exempt(views_pipe.get_master_skill_edit_info), name='get_master_skill_edit_info'),

    # [MASTER]获取技能元数据请求
    # @req:
    #     - uid: 用户uid
    #     - skill_id: 技能id
    #
    # @ack:
    #     - ranks: 技能段位列表
    #     - tags: 标签列表
    #     - screenshot_sample: 技能截图示例
    #     - min_price: 最低价格
    #     - max_price: 最高价格
    url(r'^get_skill_meta_data/$', csrf_exempt(views_pipe.get_skill_meta_data), name='get_skill_meta_data'),

    # [MASTER]获取技能列表请求
    # @req:
    #     - uid: 用户uid
    #
    # @ack:
    #     - skills: 技能列表
    url(r'^get_skill_list/$', csrf_exempt(views_pipe.get_skill_list), name='get_skill_list'),

    # [MASTER]获取技能标签列表请求
    # @req:
    #     - uid: 用户uid
    #     - skill_id: 技能id
    #
    # @ack:
    #     - tags: 标签列表
    url(r'^get_skill_tag_list/$', csrf_exempt(views_pipe.get_skill_tag_list), name='get_skill_tag_list'),

    # [MASTER]获取技能段位列表请求
    # @req:
    #     - uid: 用户uid
    #     - skill_id: 技能id
    #
    # @ack:
    #     - ranks: 技能段位列表
    url(r'^get_skill_rank_list/$', csrf_exempt(views_pipe.get_skill_rank_list), name='get_skill_rank_list'),

    # [MASTER]获取用户基本信息请求
    # @req:
    #     - uid: 用户的uid
    #     - target_uid: 查询用户的uid
    #
    # @ack:
    #     - user: 用户的开放信息
    url(r'^get_user_public_info/$', csrf_exempt(views_pipe.get_user_public_info), name='get_user_public_info'),

    # [ORDER]大神同意退款请求
    # @req:
    #     - uid: 用户uid
    #     - order_id: 订单id
    #
    # @ack:
    url(r'^master_agree_refund_order/$', csrf_exempt(views_pipe.master_agree_refund_order), name='master_agree_refund_order'),

    # [ORDER]大神开始服务请求
    # @req:
    #     - uid: 用户uid
    #     - order_id: 订单id
    #
    # @ack:
    url(r'^master_start_order/$', csrf_exempt(views_pipe.master_start_order), name='master_start_order'),

    # [ORDER]大神拒绝接单请求
    # @req:
    #     - uid: 用户uid
    #     - order_id: 订单id
    #
    # @ack:
    url(r'^master_refuse_order/$', csrf_exempt(views_pipe.master_refuse_order), name='master_refuse_order'),

    # [ORDER]大神拒绝退款请求
    # @req:
    #     - uid: 用户uid
    #     - order_id: 订单id
    #     - reason: 拒绝退款理由
    #     - proof_json: 上传凭证json(上传图片的token类型为 UPLOAD_FILE_SKILL)
    #     - comment: 备注
    #
    # @ack:
    url(r'^master_refuse_refund_order/$', csrf_exempt(views_pipe.master_refuse_refund_order), name='master_refuse_refund_order'),

    # [ORDER]大神接受订单请求
    # @req:
    #     - uid: 用户uid
    #     - order_id: 订单id
    #
    # @ack:
    url(r'^master_accept_order/$', csrf_exempt(views_pipe.master_accept_order), name='master_accept_order'),

    # [ORDER]大神获取订单列表请求
    # @req:
    #     - uid: 用户uid
    #     - count: 请求的数量(服务器控制上限)
    #     - offset: 请求偏移(首次调用时传0)
    #
    # @ack:
    #     - orders: 订单列表
    #     - next_offset: 下一次的请求偏移
    url(r'^master_get_order_list/$', csrf_exempt(views_pipe.master_get_order_list), name='master_get_order_list'),

    # [ORDER]用户下单请求
    # @req:
    #     - uid: 用户uid
    #     - mid: 用户uid
    #     - skill_id: 技能id
    #     - begin_time: 开始时间
    #     - count: 服务数量
    #     - comment: 备注
    #
    # @ack:
    #     - order_id: 订单id
    url(r'^user_place_order/$', csrf_exempt(views_pipe.user_place_order), name='user_place_order'),

    # [ORDER]用户取消订单请求
    # @req:
    #     - uid: 用户uid
    #     - order_id: 订单id
    #     - reason: 取消原因
    #
    # @ack:
    url(r'^user_cancel_order/$', csrf_exempt(views_pipe.user_cancel_order), name='user_cancel_order'),

    # [ORDER]用户取消订单退款请求
    # @req:
    #     - uid: 用户uid
    #     - order_id: 订单id
    #
    # @ack:
    url(r'^user_cancel_refund_order/$', csrf_exempt(views_pipe.user_cancel_refund_order), name='user_cancel_refund_order'),

    # [ORDER]用户支付订单请求
    # @req:
    #     - uid: 用户uid
    #     - order_id: 订单id
    #
    # @ack:
    url(r'^user_pay_order/$', csrf_exempt(views_pipe.user_pay_order), name='user_pay_order'),

    # [ORDER]用户确认完成订单请求
    # @req:
    #     - uid: 用户uid
    #     - order_id: 订单id
    #
    # @ack:
    url(r'^user_finish_order/$', csrf_exempt(views_pipe.user_finish_order), name='user_finish_order'),

    # [ORDER]用户获取订单列表请求
    # @req:
    #     - uid: 用户uid
    #     - count: 请求的数量(服务器控制上限)
    #     - offset: 请求偏移(首次调用时传0)
    #
    # @ack:
    #     - orders: 订单列表
    #     - next_offset: 下一次的请求偏移
    url(r'^user_get_order_list/$', csrf_exempt(views_pipe.user_get_order_list), name='user_get_order_list'),

    # [ORDER]用户订单申诉请求
    # @req:
    #     - uid: 用户uid
    #     - order_id: 订单id
    #     - reason: 退款理由
    #     - proof_json: 上传凭证json(上传图片的token类型为 UPLOAD_FILE_SKILL)
    #
    # @ack:
    url(r'^user_appeal_order/$', csrf_exempt(views_pipe.user_appeal_order), name='user_appeal_order'),

    # [ORDER]用户订单退款请求
    # @req:
    #     - uid: 用户uid
    #     - order_id: 订单id
    #     - refund_type: 退款类型(参见 ACRefundTypeDefine)
    #     - reason: 退款理由
    #     - comment: 备注
    #
    # @ack:
    url(r'^user_apply_refund_order/$', csrf_exempt(views_pipe.user_apply_refund_order), name='user_apply_refund_order'),

    # [ORDER]用户评论订单请求
    # @req:
    #     - uid: 用户uid
    #     - order_id: 订单id
    #     - star: 评论星级(取值1-5)
    #     - tags_json: 评论标签json
    #     - comment: 评论
    #     - isAnonymous: 是否匿名
    #
    # @ack:
    url(r'^user_comment_order/$', csrf_exempt(views_pipe.user_comment_order), name='user_comment_order'),

    # [ORDER]获取订单评论列表请求
    # @req:
    #     - uid: 查询用户的uid
    #     - mid: 大神id
    #     - count: 请求的数量(服务器控制上限)
    #     - offset: 请求偏移(首次调用时传0)
    #
    # @ack:
    #     - comments: 评论列表
    #     - next_offset: 下一次的请求偏移
    url(r'^get_order_comment_list/$', csrf_exempt(views_pipe.get_order_comment_list), name='get_order_comment_list'),

    # [ORDER]获取订单评论标签列表请求
    # @req:
    #     - uid: 用户uid
    #     - skill_id: 技能id
    #
    # @ack:
    #     - tags: 标签列表
    url(r'^get_order_comment_tag_list/$', csrf_exempt(views_pipe.get_order_comment_tag_list), name='get_order_comment_tag_list'),

    # [ORDER]获取订单评论标签统计信息请求
    # @req:
    #     - uid: 查询用户的uid
    #     - mid: 大神id
    #
    # @ack:
    #     - tags: 评论标签列表
    url(r'^get_order_comment_tag_stat_info/$', csrf_exempt(views_pipe.get_order_comment_tag_stat_info), name='get_order_comment_tag_stat_info'),

    # [ORDER]获取订单详情请求
    # @req:
    #     - uid: 用户uid
    #     - order_id: 技能id
    #
    # @ack:
    #     - order: 订单详情
    #     - refund_info: 退款详情
    url(r'^get_order_info/$', csrf_exempt(views_pipe.get_order_info), name='get_order_info'),

]